<template>
	<view>
		<image class="main-img" src="" mode="aspectFill"></image>
		<view class="content">
			<h3 class="title">极简主义</h3>
			<view class="creator">
				作者：<text>心情备忘录</text>
			</view>
			<view class="sign">
				我们献给青春最好的礼物，就是奋斗！我们献给青春最好的礼物，就是奋斗！
				我们献给青春最好的礼物，就是奋斗！我们献给青春最好的礼物，就是奋斗！
			</view>
			<view class="images">
				<image @click="viewImg(item)" :src="item" mode="aspectFill" v-for="(item,index) in images" :key="index"></image>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				images:[
					'https://cdn.uviewui.com/uview/album/4.jpg',
					'https://cdn.uviewui.com/uview/album/5.jpg',
					'https://cdn.uviewui.com/uview/album/6.jpg',
					'https://cdn.uviewui.com/uview/album/7.jpg',
					'https://cdn.uviewui.com/uview/album/8.jpg',
					'https://cdn.uviewui.com/uview/album/9.jpg',
					'https://cdn.uviewui.com/uview/album/10.jpg',
				],
			}
		},
		methods: {
			viewImg(src){
				uni.navigateTo({
					url:`/pages/view_img/view_img?src=${src}`,
				})
			}
		}
	}
</script>

<style lang="scss" scoped>
	.main-img{
		width: 100vw;
		height: 400rpx;
	}
	.content{
		.title{
			padding: 20rpx 20rpx 0;
		}
		.creator{
			margin: 10rpx 0 20rpx;
			font-size: 28rpx;
			padding: 0 20rpx;
		}
		.sign{
			padding: 0 20rpx;
			color: #666;
			font-size: 28rpx;
		}
		.images{
			display: flex;
			flex-wrap: wrap;
			margin-top: 10rpx;
			padding-left: 26rpx;
			image{
				width: $uni-img-width;
				height: $uni-img-height;
				margin-right: 10rpx;
				margin-top: 10rpx;
			}
		}
	}
</style>
